package com.pro.h5case.admin.service.impl;

import java.util.List;
import java.util.Map;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.pro.h5case.admin.service.AdminService;
import com.pro.h5case.common.mapper.BAdminMapper;
import com.pro.h5case.common.mapper.BDictionaryMapper;
import com.pro.h5case.common.mapper.BPlanMapper;
import com.pro.h5case.common.model.BAdmin;
import com.pro.h5case.common.model.BDictionary;
import com.pro.h5case.common.model.BPlan;
@Service
public class AdminServiceImpl implements AdminService {
	@Resource
	BAdminMapper adminMapper;
	@Resource
	BDictionaryMapper dicMapper;
	@Resource
	BPlanMapper planMapper;
	@Override
	public List<BAdmin> selectAdminByMap(Map<String, Object> parameter) {
		// TODO Auto-generated method stub
		return adminMapper.selectAdminByMap(parameter);
	}
	@Override
	public List<BDictionary> selectByMap(Map<String, Object> parameter) {
		// TODO Auto-generated method stub
		return dicMapper.selectByMap(parameter);
	}
	@Override
	public int insertAdmin(BAdmin admin) {
		// TODO Auto-generated method stub
		return adminMapper.insert(admin);
	}
	@Override
	public int updateAdmin(BAdmin admin) {
		// TODO Auto-generated method stub
		return adminMapper.updateByPrimaryKeySelective(admin);
	}
	@Override
	public int deleteAdminByPrimaryKey(int id) {
		// TODO Auto-generated method stub
		return adminMapper.deleteByPKey(id);
	}
	@Override
	public BAdmin selectByPirmaryKey(int id) {
		// TODO Auto-generated method stub
		return adminMapper.selectByPrimaryKey(id);
	}
	@Override
	public int countAdminByMap(Map<String, Object> parameter) {
		// TODO Auto-generated method stub
		return adminMapper.countAdminByMap(parameter);
	}
	@Override
	public int updateAdminByMap(Map<String, Object> parameter) {
		
		return adminMapper.updateAdminByMap(parameter);
	}
	

}
